package com.pcbly.web.bean.system;

import java.util.HashSet;
import java.util.Set;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;

import com.pcbly.web.bean.AbstractBaseBean;

public class MenuBean extends AbstractBaseBean {

	/**
	 * 
	 */
	private static final long serialVersionUID = 3282583767299153149L;
	private String name;
	private String description;
	private String image;
	private String forward;
	private String target;
	private int orderBy;
	private String parentId;
	private Set<MenuBean> menuBeans=new HashSet<MenuBean>(0); 
//	
	private MenuBean parent;
	
	public String getParentId() {
		return parentId;
	}

	public void setParentId(String parentId) {
		this.parentId = parentId;
	}

	public MenuBean(){
		
	}
	public MenuBean getParent() {
		return parent;
	}

	public void setParent(MenuBean parent) {
		this.parent = parent;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	} 

	public String getImage() {
		return image;
	}

	public void setImage(String image) {
		this.image = image;
	}

	public String getForward() {
		return forward;
	}

	public void setForward(String forward) {
		this.forward = forward;
	}

	public String getTarget() {
		return target;
	}

	public void setTarget(String target) {
		this.target = target;
	}

	public int getOrderBy() {
		return orderBy;
	}

	public void setOrderBy(int orderBy) {
		this.orderBy = orderBy;
	} 
 

	/**
	 * @see java.lang.Object#equals(Object)
	 */
	public boolean equals(Object object) {
		return EqualsBuilder.reflectionEquals(this, object);
	}

	/**
	 * @see java.lang.Object#hashCode()
	 */
	public int hashCode() {
		return HashCodeBuilder.reflectionHashCode(this);
	}

	/**
	 * @see java.lang.Object#toString()
	 */
	public String toString() {
		return ToStringBuilder.reflectionToString(this,
				ToStringStyle.MULTI_LINE_STYLE);
	}
	public void setDescription(String description) {
		this.description = description;
	}
	public String getDescription() {
		return description;
	}
	public void setMenuBeans(Set<MenuBean> menuBeans) {
		this.menuBeans = menuBeans;
	}
	public Set<MenuBean> getMenuBeans() {
		return menuBeans;
	}
}
